MyWorkFlow
MyWorkFlow Just a small documentation on how I use tovid suite of tools. This is a mini howto for making dvd disc from avi video clips. =Basic Steps= Encode avi to mpg I take all the default from tovid since most downloaded clips are in dvd kind of aspect ratio and ntsc frame rate, and my dvd player and tv can handle both pal and ntsc anyway. So I repeat the command line for all the avi. $ tovid -in c1.avi -out c1 Create dvd disk structure Again I take all the default. The only thing I need to make sure is that all .mpg files total up is less then 4.4gb. $ todisc -files c1.mpg c2.mpg c3.mpg -titles "clip1" "clip2" clip3" -out dvd Burn the disk I check again to make sure that the output dir (dvd) is below 4.4gb before I burn the disk. $ makedvd -burn dvd =Fine Tuning= The default provided by tovid is quite good for most clip but there are always preferences Reduce the bitrate Since all download .avi are not top of the line kind of content lower the bitrate does not really impact the quality. I find vbitrate at 2000 is actually good enough in most cases. I would just set it at 3000. $ tovid -in c1.avi -out c1 -vbitrate 3000 Adjust Audio Level Normalize the audio level is necessary. Most video clips came with different audio volume. It is always nice to normalize them. More importantly I want my dvd's audio level for my dvd player to match the level of my TV program's volume. I find that normalize provide a volume a bit lower for my dvd player. So, I do a ''-amplitude 0.4'' to push the volume up. $ tovid -in c1.avi -out c1 -amplitude 0.4 Check Video/Audo sync I would also check the result mpg using mplayer to make sure that the video and audio are in sync. I use "+" "-" key in mplayer to adjust the sync while playing.If need be I do a postproc to adjust the out-of-sync problem using the delay number from mplayer. c1a.mpg is the adjusted file with audio playing faster by 200ms for example. $ postproc -audiodelay -200 c1.mpg c1a.mpg Set Chain Play todisc by default stop at each clip and return to menu on a dvd player. You can decide if each clip should chain play the next or stop at menu after play. For example, if I have a 5 clips dvd and they make up of 2 full movies. I would use the following command to produce the dvd. $ todisc -files c1.mpg c2.mpg c3.mpg c4.mpg c5.mpg \ -titles "movie part1" "movie1 part2" "movie2 part1" "movie2 part2" movie2 part3" \ -out dvd \ -chain-video chain break chain chain break Animation clip If the clip is the animation video, it maybe good to add an option -type animation to improve the quality. $ tovid -in c1.avi -out c1 -amplitude 0.4 -type animation Add contrast At time if the clips is too "white", I would add contrast filter. $ tovid -in c1.avi -out c1 -amplitude 0.4 -filter contrast Preview Before burning the disk it is always nice to preview the dvd. Some how xine need full path to the dvd file system. ./dvd would not work. $ xine dvd:/full/path/to/dvd Working Environment Take a look at ~/.tovid directory. I would edit the ~/.tovid/preferences to include the following two lines. This way all temp files will be created in one place, so are the completed mpg files. In my case I like the mpg accessiable from desktop. Also, remember to create that output directory you specified. Encoding job will fail at the end if tovid could not find the output directory. If tovid could not find the tmp directory it will place all temp file on the root (/), as of version 0.28. WORKING_DIR=/tmp OUTPUT_DIR=~/Desktop/output =Automation= If you are using gnome 2.14 and up, you can try this out as well. I wrote this simple script to front-end the tovid. I called it todvd, it has all my preferences/default parameters and it can be kick off from gnome desktop with a few click, without touching the command line. Basically, I can now run the script again any .avi file(s) I picked. todvd script (how to include bash script here? I tried no good) Setup I'm using gnome's nautilus-script feature. Here is how it work. $ mkdir ~/Desktop/dvd #output folder on desktop. $ mkdir ~/.gnome2/nautilus-scripts #create this directly under home to house the scripts $ mv tovid ~/.gnome2/nautilus-scripts #move the script in there after editing if necessary I think we need to logout and login again before we start. How it work Single file - On the gnome desktop, I now can open the folder contain my .avi files. Lets pick/select/highlight c1.avi, right click, select Script, and choose todvd. The script will kick off tovid and the end result c1.mpg will be placed in your desktop dvd folder. The script also create a file c1.avi.12345 log file while the processing is going on. You can review the log file using gedit anytime. When the processing is completed this log file will be renamed c1.avi.12345.done and seat beside c1.avi. It tell me it is done. :) "12345" is a the process id so it will be unique. Multiple files - I can pick multiple .avi and kick the script off the same way. It will process all the selected files, one file at a time. It will left me with the .mpg files in dvd and one log files per .avi as well. I just need to check to see c1.avi.12345.done is there. If I don't see .done appended to the of the log file I know it is still working on it. I need to review the log's content only if .mpg is not created in dvd folder. Now I have a gui app on tovid. :) =Dream enhancement= These are just a few enhancements that I think would be useful, at least for my workflow. Selective encode Before the encoding work sometime I cut the video a little using avidemux. This is not part of tovid. :) It would be nice if tovid can do -start -end to cut put just the needed content to mpg. For example to discard the 1st 2 minutes and stop at 25 minutes and 10 frames into the clip. $ tovid -in c1.avi -out c1 -start 00:02:00 -end 00:25:10 Chain/Break and loop I would prefer the -chain-video to work as follow. -chain-video tell the player to play the next clip at the end of each clip, except or end at the last than go to menu. The -loop tell the player jump to clip 1 (loop to front). -break 2 tell the player to return to menu after clip 2 (end of movie1). $ todisc -files c1.mpg c2.mpg c3.mpg c4.mpg c5.mpg \ -titles "movie1 part1" "movie1 part2" "movie2 part1" "movie2 part2" movie2 part3" \ -out dvd \ -chain-video -loop -break 2 Cut out those black bars Some 4:3 clips came with black bar on top and bottom. They are originally 16x9 clips, the black bar was added to make tham 4:3. It would be nice if tovid can do the following, $ tovid -in c1.avi -out c1 -cutblack =GUI workflow if possible= Doing it all in full GUI environment is still not possible now. But...dream on.... --later-- to be continued... //oh.july,2006